<template>
        <div>

                <mt-cell v-for="(item,index) in carts" :key="index" :title="item.name.slice(0,10)">
                <span class="price">{{item.price}}</span>X{{item.num}} 
                 <img slot="icon" v-lazy="`http://localhost:3000/${item.img.filename}`" width="24" height="24">
</mt-cell>
                   <mt-cell class="pos" is-link title="总计价格为:">
                        <span class="price">{{totalMoney}}</span> 
                 
                        </mt-cell>  
        </div>
</template>
<script>
import { mapGetters, mapActions } from "vuex";
export default {
  data(){
       return{
          
      }
  },
  computed: {
          ...mapGetters(["carts", "totalMoney"])
  }

}
</script>
<style lang="scss">
.price{
color:red;
font-size:16px;
font-family:'Verdana';
}
.pos{
        width: 100%;
        position: absolute;
        bottom: 40px
}
</style>
